package com.hssy.wululuaplan.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 收支账本记录
 * </p>
 *
 * @author Mr.Hongtao
 * @since 2025-06-18
 */
@Getter
@Setter
@TableName("keep_account")
@ApiModel(value = "KeepAccount对象", description = "收支账本记录")
public class KeepAccount implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id",type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("分类")
    @TableField("category")
    private Integer category;

    @ApiModelProperty("事项")
    @TableField("event")
    private String event;

    @ApiModelProperty("金额")
    @TableField("money")
    private BigDecimal money;

    @ApiModelProperty("类型： 0 支出   1 收入")
    @TableField("type")
    private Integer type;

    @ApiModelProperty("用户id")
    @TableField("user_id")
    private Integer userId;

    @ApiModelProperty("日期")
    @TableField("happen_date")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date happenDate;

    @ApiModelProperty("创建日期")
    @TableField("create_time")
    private Date createTime;

    @ApiModelProperty("修改日期")
    @TableField("update_time")
    private Date updateTime;


}
